import java.io.IOException;
import java.util.ArrayList;
import java.util.List;


public class InputReader extends Reader{

	InputReader(String fileName) {
		super(fileName);
	}
	public List readFile(){
		List<Integer> values = new ArrayList();
		try {
			int n = Integer.parseInt(this.reader.readLine());
			int k = Integer.parseInt(this.reader.readLine());
			values.add(k);
			while(n-- >0){
				String line = this.reader.readLine();
				int value = Integer.parseInt(line.trim());
				values.add(value);
			}
		} catch (NumberFormatException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}
		return values;
	}
	public static void main(String[] args) {
		InputReader reader = new InputReader("C:\\sivravis\\dev\\study\\my-alg-exer\\BillGatesWithChoclates\\src\\input.txt");
		List values = reader.readFile();
		System.out.println(values);
		reader.close();
	}
}
